<template>
	<view class="main-page">
		<view class="column-container width-100p">
			<view class="shop-item" v-for="(item , index) in shopList" :key="index"
			@click="changeChosenShop(item)">
				<view class="divider"></view>
				<text class="font-333-32 font-bold ml-30">艾灸馆（长沙市滨江分店）</text>
				<image class="chosen-flag" src="../../static/common/ic_agree.png"
				v-if="chosenShop == item"></image>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				shopList:[0,1,2,3,4,5],
				chosenShop:0
			}
		},
		methods: {
			changeChosenShop(item){
				console.log('changeShop---' , item)
				this.chosenShop = item
			}
		}
	}
</script>

<style lang="scss">
	.shop-item{
		display: flex;
		flex-direction: row;
		align-items: center;
		justify-content: space-between;
		width: 100%;
		height: 130rpx;
		background: white;
		position: relative;
		
		.divider{
			width: calc(100% - 30rpx);
			height: 1rpx;
			background: #E8E8E8;
			margin-left: 30rpx;
			position: absolute;
			bottom: 0;
		}
		
		.chosen-flag{
			width: 40rpx;
			height: 40rpx;
			margin-right: 30rpx;
		}
	}
</style>
